package pfc.etsii.ull.es.server;


import java.io.FileInputStream;
import java.io.FileNotFoundException;

import javax.xml.bind.JAXBContext;
import javax.xml.bind.JAXBException;
import javax.xml.bind.Unmarshaller;

import pfc.etsii.ull.es.shared.generated.Informe;

public class XMLfile {
	private Informe xmlGrafica;
	
	public Informe getXmlGrafica () throws JAXBException, FileNotFoundException {
		JAXBContext jc = JAXBContext.newInstance( "pfc.etsii.ull.es.shared.generated" );
		Unmarshaller u = jc.createUnmarshaller(); 
		//Informe po = (Informe) u.unmarshal( new FileInputStream( "/Users/daniel/Desktop/prueba.xml" ) );
		//this.xmlGrafica = (Informe) u.unmarshal( new FileInputStream( "/Users/daniel/Desktop/KatzvsMini.xml" ) );
		Informe inf = (Informe) u.unmarshal( new FileInputStream( "./subido.xml" ) );
		return inf;
		
	}

	

	public void setXmlGrafica(Informe xmlGrafica) {
		this.xmlGrafica = xmlGrafica;
	}
	
	
	

}
